<# # It is recommended to test the script on a local machine for its purpose and effects. # ManageEngine Endpoint Central will not be responsible for any # damage/loss to the data/setup based on the behavior of the script. # Description: Script is designed To fetch device model # Configuration Type - COMPUTER #> # Get the MachineID from the registry $path = "HKLM:\SOFTWARE\Microsoft\SQMClient" $Name = "MachineID" try { # Retrieve the value $value = (Get-ItemProperty -Path $path -Name $Name).$Name # Output the value Write-Host "Device model is $value" } catch { Write-Host "MachineID not found or registry path is invalid." }